import Vue from 'vue'
import App from './App.vue'

import VueRouter from "vue-router";
import ElementUI, {Message} from 'element-ui'

import 'element-ui/lib/theme-chalk/index.css'
import axios from 'axios'
import router from "./router/router"
import Antd from 'ant-design-vue';

Vue.config.productionTip = false
axios.interceptors.request.use(config=>{
  config.headers.Authorization=window.sessionStorage.getItem('token')//设置请求头return config
  return config//要返回结果
})
axios.defaults.withCredentials = true
Vue.prototype.$http = axios

Vue.prototype.$message = Message;
Vue.use(ElementUI)
Vue.use(axios)
Vue.use(Antd)
Vue.prototype.GLOBAL = global
Vue.use(VueRouter)
Vue.config.productionTip = false

new Vue({
  render: h => h(App),
  router
}).$mount('#app')
